Rz = 6400000;
Rorb = 19100000;
Rob = Rz + Rorb;
Tobr = 12*3600;
dt = Tobr/1000;
t = 0:dt:2*Tobr;
fi = (2*pi*t)/Tobr;

x = Rob*cos(fi);
y = Rob*sin(fi);

for i = 1:(length(fi)-1)
Vx(i) = (x(i+1) - x(i))/dt;
Vy(i) = (y(i+1) - y(i))/dt;
Vo(1:2,i) = [ Vx(i) Vy(i)];
Rpsp(1:2,i) = [ x(i) y(i)] - [ 0 Rz];
Vsbl(1:2,i) = -((dot(Rpsp(1:2,i),Vo(1:2,i)))./norm(Rpsp(1:2,i)));

tt(i) = i;
end

V = (2*pi*Rob)/Tobr;
% plot(x,y);
figure
plot(x,y)
title('traj')
figure
plot(Vx,Vy)
title('sat velocity')

figure
plot(tt,Vsbl);
title('dopler')


 

